package com.directorio.modelo.utiles.pojo;

import java.util.ArrayList;
import java.util.Calendar;
import java.util.GregorianCalendar;
import java.util.List;

public class Funciones {
	
	public static String[] getArrayStringFromList(List<String> list){
		int _tam = list.size();
		String arr[] = new String[_tam];
		int i = 0;
		for(String str:list){
			arr[i++] = str;
		}
		return arr;
	}
	public static List<String> getListStringFromArray(String []array){
		List<String> ret = new ArrayList<String>();
		for(String arr:array){
			ret.add(arr);
		}
		return ret;
	}
	public static String getFechaActual(){
		Calendar c = new GregorianCalendar();
		String dia = Integer.toString(c.get(Calendar.DATE));
		String mes = Integer.toString(c.get(Calendar.MONTH));
		String annio = Integer.toString(c.get(Calendar.YEAR));
		return annio+"-"+mes+"-"+dia;
	}
}
